﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TestRef
{
    internal class PersonCollection
    {
        private Person[] peoples =
        {
            new Person (){
            Name="chen",Grade ="211"},
            new Person()
            {
                Name ="kai",
                Grade ="213"
            },
        };


        private Person person = null;
        public Person GetPerson(string name)
        {
            foreach (Person p in peoples)
            {
                if (p.Name == name)
                {
                    return p;
                }
            }
            return person;
        }
    }
}
